﻿/*              Copyright(c) 2008 Dave Sexton              *
 * http://www.codeplex.com/DocProject                      *
 * http://www.codeplex.com/DocProject/Project/License.aspx *
 ***********************************************************/
using System;
using System.Collections.Generic;
using System.Text;

namespace DaveSexton.DocToMaml
{
	/// <summary>
	/// Provides arguments for the <see cref="ConversionContext.BeforeConvertInput"/> and 
	/// <see cref="ConversionContext.AfterConvertInput"/> events.
	/// </summary>
	[Serializable]
	internal sealed class ConvertEventArgs : EventArgs
	{
		#region Public Properties
		public IInput Input
		{
			get
			{
				return input;
			}
		}

		public int ProgressPercentage
		{
			get
			{
				return progressPercentage;
			}
		}
		#endregion

		#region Private / Protected
		private readonly IInput input;
		private readonly int progressPercentage;
		#endregion

		#region Constructors
		/// <summary>
		/// Constructs a new instance of the <see cref="ConvertEventArgs" /> class.
		/// </summary>
		public ConvertEventArgs(IInput input, int progressPercentage)
		{
			if (input == null)
				throw new ArgumentNullException("input");

			this.input = input;
			this.progressPercentage = progressPercentage;
		}
		#endregion
	}
}
